# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=xkeyboard-config
pkgver=2.30
pkgrel=0
pkgdesc="X keyboard configuration files"
url="http://www.freedesktop.org/wiki/Software/XKeyboardConfig"
arch="noarch"
license="MIT"
subpackages="$pkgname-doc"
makedepends="xkbcomp intltool libx11-dev libxslt python3"
source="https://www.x.org/archive/individual/data/xkeyboard-config/xkeyboard-config-$pkgver.tar.bz2
	"

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--with-xsltproc \
		--with-xkb-base=/usr/share/X11/xkb \
		--with-xkb-rules-symlink=xorg \
		--enable-compat-rules=yes
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
	rm -f "$pkgdir"/usr/share/X11/xkb/compiled
	install -m755 -d "$pkgdir"/var/lib/xkb
	mkdir -p "$pkgdir"/usr/lib
	mv "$pkgdir"/usr/share/pkgconfig "$pkgdir"/usr/lib
}
sha512sums="2d775dcaab49d80f62b8eaadc9be406b42c9a3643d3a360f864a462c61865abce67d0a8a80772d54f8136603114c61b5168fd06771f9c132411911914abb1ea4  xkeyboard-config-2.30.tar.bz2"
